﻿package com.tudou.newPlayer
{
    import flash.events.*;

    public class TudouAdPlayer extends VideoPlayer
    {

        public function TudouAdPlayer(param1:uint = 400, param2:uint = 300)
        {
            super(param1, param2);
            return;
        }// end function

        override public function close() : void
        {
            setMasks(null);
            rotateType = 0;
            changeStatus(VideoStatus.STOPPED);
            _metaData = null;
            _playURL = "";
            adResetBody();
            return;
        }// end function

        private function adResetBody() : void
        {
            if (netStream)
            {
                netStream.removeEventListener(NetStatusEvent.NET_STATUS, streamStatus);
                netStream.close();
            }
            netStream = null;
            if (netConnetion)
            {
                netConnetion.removeEventListener(NetStatusEvent.NET_STATUS, connectStatus);
                netConnetion.close();
            }
            netConnetion = null;
            return;
        }// end function

    }
}
